package com.jboltai.event.ai;

import com.jboltai.capability.message.AIMessage;
import com.jboltai.event.Event;
import com.jboltai.event.IEvent;
import com.jboltai.event.handler.EventHandler;
import com.jboltai.resource.ai.AIModel;

import java.util.List;
import java.util.Map;

public interface IAIEvent<T extends Event, ResultType, HandlerType extends EventHandler> extends IEvent<T, ResultType, HandlerType> {
    Map<String, Object> getParams();

    T setParams(Map<String, Object> params);

    T addParam(String key, Object value);
    <V> V getParam(String key);
    T bindAIResource(String resourceId);

    T setTemperature(Double temperature);

    T setTopP(Double topP);
    T setTopK(Integer topK);

    String getAIResource();

    String getModelName();

    AIModel getModel();

    Double getTemperature();

    Double getTopP();

    Integer getTopK();

    List<AIMessage> getMessages();

    T contextMessages(List<AIMessage> contextMessages);

    T systemMessage(String content);

    T userMessage(String content);

    T userMessage(String content, String... imgUrls);

    T assistantMessage(String content);

    T setModel(AIModel model);

    T setModelName(String modelName);

    String getPrompt();

    T prompt(String prompt);

    T imgs(String... imgUrls);

    T prompt(String template, Object... values);

    boolean isTextInput();

    void setTextInput(boolean textInput);

    boolean isImageInput();

    void setImageInput(boolean imageInput);

    boolean isAudioInput();

    void setAudioInput(boolean audioInput);

    boolean isVideoInput();

    void setVideoInput(boolean videoInput);
}
